cmake_minimum_required(VERSION 3.10)

# 设置项目名称
project(MyProject)

# 指定 vcpkg 工具链文件
if(CMAKE_TOOLCHAIN_FILE)
  message(STATUS "Using toolchain file: ${CMAKE_TOOLCHAIN_FILE}")
else()
  set(DCMAKE_TOOLCHAIN_FILE "D:/programs/vcpkg/scripts/buildsystems/vcpkg.cmake" CACHE STRING "Vcpkg toolchain file")
endif()

# 查找 fmt 包
find_package(fmt CONFIG REQUIRED)

# 添加可执行文件
add_executable(MyExecutable src/main.cpp)

# 链接 fmt 库
target_link_libraries(MyExecutable PRIVATE fmt::fmt)
